package com.cloud.xtools.user.domain.request.admin;

import com.cloud.xtools.common.validator.annotation.FieldUnique;
import com.cloud.xtools.user.domain.entity.Role;
import lombok.Data;

import java.time.LocalDateTime;

@Data
public class RoleUpdateRequest {
    private Long id;
    @FieldUnique(entity = Role.class, field = "name", ignoreField = "id", message = "角色名已存在")
    private String name;
    private final LocalDateTime updatedAt = LocalDateTime.now();
}
